-- GENERATED SPELL FOR [Mottled Scytheclaw] --


function spell0_1022(pUnit, Event) --@Claw,n/a--
pUnit:FullCastSpellOnTarget(16830,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_1022', 671, 1)
end

function spell1_1022(pUnit, Event) --@Rend Flesh,n/a--
pUnit:FullCastSpellOnTarget(3147,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_1022', 12000, 1)
end

function Sorts_1022(pUnit, Event)
local choix_sorts_1022 = math.random(0, 1)
if choix_sorts_1022 == 0 then
pUnit:RegisterEvent('spell0_1022', 1, 1)
end
if choix_sorts_1022 == 1 then
pUnit:RegisterEvent('spell1_1022', 1, 1)
end
end

function mob1022_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_1022', math.random(1500, 3000), 1)
end

function mob1022_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob1022_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob1022_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(1022, 1, 'mob1022_Action')
RegisterUnitEvent(1022, 2, 'mob1022_Leave')
RegisterUnitEvent(1022, 3, 'mob1022_Kill')
RegisterUnitEvent(1022, 4, 'mob1022_Die')
